﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace furion.blog.Utils
{
    public static class StrUtil
    {

        /// <summary>
        /// 字符串转列表
        /// </summary>
        /// <param name="str"></param>
        /// <param name="spot"></param>
        /// <returns></returns>
        public static List<string> StrToList(string str, string spot) {
            return new List<string>(str.Split(spot));
        }

        /// <summary>
        /// 列表转字符串
        /// </summary>
        /// <param name="list"></param>
        /// <param name="spot"></param>
        /// <returns></returns>
        public static string ListToStr(List<string> list,string spot) {
            return string.Join(spot,list);
        }

    }
}
